Optimal. Leaf size=18 \[ -\frac {\log (\cos (x))}{a}+\frac {\log (1+\cos (x))}{a} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 18, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 4, integrand size = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.364, Rules used = {2786, 36, 29,
31} \begin {gather*} \frac {\log (\cos (x)+1)}{a}-\frac {\log (\cos (x))}{a} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 29
Rule 31
Rule 36
Rule 2786
Rubi steps
\begin {align*} \int \frac {\tan (x)}{a+a \cos (x)} \, dx &=-\text {Subst}\left (\int \frac {1}{x (a+x)} \, dx,x,a \cos (x)\right )\\ &=-\frac {\text {Subst}\left (\int \frac {1}{x} \, dx,x,a \cos (x)\right )}{a}+\frac {\text {Subst}\left (\int \frac {1}{a+x} \, dx,x,a \cos (x)\right )}{a}\\ &=-\frac {\log (\cos (x))}{a}+\frac {\log (1+\cos (x))}{a}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.02, size = 12, normalized size = 0.67 \begin {gather*} \frac {2 \tanh ^{-1}(1+2 \cos (x))}{a} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.07, size = 17, normalized size = 0.94
method | result | size |
derivativedivides | \(-\frac {\ln \left (\cos \left (x \right )\right )-\ln \left (\cos \left (x \right )+1\right )}{a}\) | \(17\) |
default | \(-\frac {\ln \left (\cos \left (x \right )\right )-\ln \left (\cos \left (x \right )+1\right )}{a}\) | \(17\) |
risch | \(\frac {2 \ln \left ({\mathrm e}^{i x}+1\right )}{a}-\frac {\ln \left ({\mathrm e}^{2 i x}+1\right )}{a}\) | \(28\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.27, size = 18, normalized size = 1.00 \begin {gather*} \frac {\log \left (\cos \left (x\right ) + 1\right )}{a} - \frac {\log \left (\cos \left (x\right )\right )}{a} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.39, size = 20, normalized size = 1.11 \begin {gather*} -\frac {\log \left (-\cos \left (x\right )\right ) - \log \left (\frac {1}{2} \, \cos \left (x\right ) + \frac {1}{2}\right )}{a} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \frac {\int \frac {\tan {\left (x \right )}}{\cos {\left (x \right )} + 1}\, dx}{a} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.47, size = 19, normalized size = 1.06 \begin {gather*} \frac {\log \left (\cos \left (x\right ) + 1\right )}{a} - \frac {\log \left ({\left | \cos \left (x\right ) \right |}\right )}{a} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.40, size = 14, normalized size = 0.78 \begin {gather*} -\frac {\ln \left ({\mathrm {tan}\left (\frac {x}{2}\right )}^2-1\right )}{a} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________